package com.api.league.service;

import com.api.core.service.Service;
import com.api.league.model.LeagueTeam;
import com.api.league.vo.LeagueTeamMembersVo;
import com.api.league.vo.LeagueTeamVo;
import com.github.pagehelper.PageInfo;

import java.util.Collection;
import java.util.List;
import java.util.Map;

/**
 * @author RenQiang
 * @date 2021/5/28
 */
public interface LeagueTeamService extends Service<LeagueTeam> {
    /**
     * 根据战队ID批量删除联赛战队
     *
     * @param leagueId 联赛ID
     * @param teamIds  战队ID集合
     */
    void deleteByTeamIds(Long leagueId, Collection<Long> teamIds);

    /**
     * 分页查询联赛战绩
     *
     * @param conditionMap
     * @param page
     * @param size
     * @return
     */
    PageInfo<LeagueTeamVo> findByPage(Map<String, Object> conditionMap, Integer page, Integer size);

    /**
     * 获取联赛下的战队和成员
     *
     * @param leagueId
     * @param conditions
     * @return
     */
    List<LeagueTeamMembersVo> listDetail(Long leagueId, Map<String, Object> conditions);
}
